﻿using System;
using System.Collections.Generic;
using System.Text;

namespace UcAsp.Net.ModelCreate
{
    public class Sql2Csharp
    {
        
        public static List<Property> List()
        { 
            List<Property> list=new System.Collections.Generic.List<Property>();
                Property p = new Property();

                p.SqlType = "bigint";
                p.CsharpType = "Int64";
                list.Add(p);
                Property p1 = new Property();
                p1.SqlType = "int";
                p1.CsharpType = "int";
                list.Add(p1);

                Property p2 = new Property();
                p2.SqlType = "smallint";
                p2.CsharpType = "int16";
                list.Add(p2);

                Property p3 = new Property();
                p3.SqlType = "tinyint";
                p3.CsharpType = "byte";            
                list.Add(p3);

                Property p4 = new Property();
                p4.SqlType = "bit";
                p4.CsharpType = "bool";            
                list.Add(p4);

                Property p5 = new Property();
                p5.SqlType = "decimal";
                p5.CsharpType = "decimal";            
                list.Add(p5);

                Property p6 = new Property();
                p6.SqlType = "numeric";
                p6.CsharpType = "decimal";
                list.Add(p6);

                Property p7 = new Property();
                p7.SqlType = "money";
                p7.CsharpType = "decimal";
                list.Add(p7);

                Property p8 = new Property();
                p8.SqlType = "smallmoney";
                p8.CsharpType = "decimal";
                list.Add(p8);

                Property p9 = new Property();
                p9.SqlType = "float";
                p9.CsharpType = "double";
                list.Add(p9);

                Property p10 = new Property();
                p10.SqlType = "real";
                p10.CsharpType = "Single";            
                list.Add(p10);

                Property p11 = new Property();
                p11.SqlType = "datetime";
                p11.CsharpType = "DateTime";
                list.Add(p11);

                Property p12 = new Property();
                 p12.SqlType = "smalldatetime";
                p12.CsharpType = "DateTime";
                list.Add(p12);

                Property p13 = new Property();
                p13.SqlType = "char";
                p13.CsharpType = "string";            
                list.Add(p13);

                Property p14 = new Property();
                p14.SqlType = "varchar";
                p14.CsharpType = "string";
                list.Add(p14);

                Property p15 = new Property();
                p15.SqlType = "text";
                p15.CsharpType = "string";
                list.Add(p15);

                Property p16 = new Property();
                p16.SqlType = "nchar";
                p16.CsharpType = "string";
                list.Add(p16);

                Property p17 = new Property();
                p17.SqlType = "nvarchar";
                p17.CsharpType = "string";
                list.Add(p17);

                Property p18 = new Property();
                p18.SqlType = "ntext";
                p18.CsharpType = "string";
                list.Add(p18);

                Property p19 = new Property();
                p19.SqlType = "binary";
                p19.CsharpType = "byte[]";
                list.Add(p19);
                Property p20 = new Property();
                p20.SqlType = "varbinary";
                p20.CsharpType = "byte[]";
                list.Add(p20);

                Property p21 = new Property();
                p21.SqlType = "image";
                p21.CsharpType = "byte[]";
                list.Add(p21);

                Property p22 = new Property();
                p22.SqlType = "timestamp";
                p22.CsharpType = "DateTime";
                list.Add(p22);

                Property p23 = new Property();
                p23.SqlType = "uniqueidentifier";
                p23.CsharpType = "Guid";            
                list.Add(p23);

                Property p24 = new Property();
                p24.SqlType = "Variant";
                p24.CsharpType = "object";
                list.Add(p);

                Property p25 = new Property();
                p25.SqlType = "sysname";
                p25.CsharpType = "object";
                list.Add(p);
            return list;
        }
    }
    public class Property
    {
        public string SqlType { get; set; }
        public string CsharpType { get; set; }
    }
}
